home *** CD-ROM | disk | FTP | other *** search
/ TPUG - Toronto PET Users Group / TPUG Users Group CD / TPUG Users Group CD.iso / AMIGA / AMICUS / AMICUS04.ADF / image.ed / modmenu.c < prev    next >
C/C++ Source or Header  |  1985-10-26  |  19KB  |  583 lines

  1.  
  2. /************* mod.menu.c ****************/
  3.  
  4. #include "intuall.h"
  5. #include "imageedit.h"
  6.  
  7.  
  8. struct Menu menu[6];            /* two major menu items present */
  9. struct MenuItem choiceitem[9];
  10. struct MenuItem choiceitem2[9];
  11.  
  12. struct IntuiText choicetext[9];
  13. struct MenuItem diskitem[2];
  14. struct IntuiText disktext[2];
  15. struct IntuiText directtext[5]; /* text to use for move */
  16. struct IntuiText movereqtext[2];
  17.  
  18.  
  19. struct MenuItem copyitem[4];
  20. struct MenuItem moveitem[3];
  21. struct MenuItem textitem[2];
  22. struct MenuItem miscitem[5];
  23.  
  24. struct IntuiText copytext[4];
  25. struct IntuiText movetext[3];
  26. struct IntuiText texttext[2];
  27. struct IntuiText misctext[5];
  28.  
  29. struct MenuItem jamitem[2];
  30. struct MenuItem topazitem[2];
  31.  
  32. struct IntuiText jamtext[2];
  33. struct IntuiText topaztext[2];
  34.  
  35. extern struct MenuItem coloritem[];
  36.  
  37. struct TextAttr TestFont =
  38.     {
  39.     "topaz.font",
  40.     TXHEIGHT,
  41.     0,
  42.     0,
  43.     };
  44.  
  45.  
  46. struct Gadget DoneGadget = {
  47.         NULL,                           /* address of next gadget */
  48.         12,50,40,10,                    /* left,top,width,height of hitbox */
  49.         GADGHCOMP,                      /* flags */
  50.         RELVERIFY | GADGIMMEDIATE | ENDGADGET,  
  51.                                         /* tell me only when he releases the
  52.                                          * mouse button and if over the
  53.                                          * gadget at that time */       
  54.         REQGADGET | BOOLGADGET,         /* is a requestor, boolean */
  55.         NULL,                           /* BORDER descriptor */
  56.         NULL,                           /* SELECT descriptor */
  57.         &directtext[4],
  58.         0,                              /* mutual exclusion (could use) */
  59.         NULL,                           /* special info */
  60.         4,                              /* gadget identifier, user */
  61.         NULL };                         /* user data pointer */
  62.  
  63. struct Gadget DownGadget = {
  64.         &DoneGadget,                    /* address of next gadget */
  65.         40,36,40,10,                    /* left,top,width,height of hitbox */
  66.         GADGHCOMP,                      /* Flags */
  67.         RELVERIFY | GADGIMMEDIATE,      /* Activation flags */
  68.         REQGADGET | BOOLGADGET,         /* is a requestor, boolean */
  69.         NULL,                           /* BORDER descriptor */
  70.         NULL,                           /* SELECT descriptor */
  71.         &directtext[3],                 /* intiutext to write there */
  72.         0,                              /* mutual exclusion (could use) */
  73.         NULL,                           /* special info */
  74.         3,                              /* gadget identifier, user */
  75.         NULL };                         /* user data pointer */
  76.  
  77. struct Gadget UpGadget = {
  78.         &DownGadget,                    /* address of next gadget */
  79.         48,14,20,10,                    /* left,top,width,height of hitbox */
  80.         GADGHCOMP,                      /* Flags, rel. to upperleft (normal) */
  81.         RELVERIFY | GADGIMMEDIATE,      /* Activation flags */
  82.         REQGADGET | BOOLGADGET,         /* is a requestor, boolean */
  83.         NULL,                           /* BORDER descriptor */
  84.         NULL,                           /* SELECT descriptor */
  85.         &directtext[2],                 /* intiutext to write there */
  86.         0,                              /* mutual exclusion (could use) */
  87.         NULL,                           /* special info */
  88.         2,                              /* gadget identifier, user */
  89.         NULL };                         /* user data pointer */
  90.  
  91. struct Gadget RightGadget = {
  92.         &UpGadget,                      /* address of next gadget */
  93.         60,25,45,10,                    /* left,top,width,height of hitbox */
  94.         GADGHCOMP,                      /* Flags, complement select box  */
  95.         RELVERIFY | GADGIMMEDIATE,      /* Activation flags */
  96.         REQGADGET | BOOLGADGET,         /* is a requestor, boolean */
  97.         NULL,                           /* BORDER descriptor */
  98.         NULL,                           /* SELECT descriptor */
  99.         &directtext[1],                 /* intiutext to write there */
  100.         0,                              /* mutual exclusion (could use) */
  101.         NULL,                           /* special info */
  102.         1,                              /* gadget identifier, user */
  103.         NULL };                         /* user data pointer */
  104.  
  105. struct Gadget LeftGadget = 
  106.         {
  107.         &RightGadget,                   /* next gadget */
  108.         20,25,34,10,                    /* left,top,width,height of hitbox */
  109.         GADGHCOMP,                      /* Flags, complement select box  */
  110.         RELVERIFY | GADGIMMEDIATE,      /* Activation flags */
  111.         REQGADGET | BOOLGADGET,         /* Type ... is a requestor, boolean */
  112.         NULL,                           /* BORDER image */
  113.         NULL,                           /* SELECT image */
  114.         &directtext[0],                 /* intiutext to write there */
  115.         0,                              /* No mutual exclusion (could use) */
  116.         NULL,                           /* special info */
  117.         0,                              /* gadget identifier, user */
  118.                                         /* RETURNED IN code-field */ 
  119.         NULL };                         /* no user data pointer */
  120.  
  121.  
  122.  
  123. struct Requester myrequest;
  124.  
  125. InitMyRequest()         
  126. {
  127.         InitRequester(&myrequest);
  128.         myrequest.LeftEdge = 10;
  129.         myrequest.TopEdge = 20;
  130.         myrequest.Width = 140;
  131.         myrequest.Height = 60;
  132.         myrequest.ReqGadget = &LeftGadget;
  133.         myrequest.ReqText = &movereqtext[0];    
  134.         myrequest.BackFill = 1;
  135.  
  136.         movereqtext[0].FrontPen = 0;
  137.         movereqtext[0].BackPen = 1;
  138.         movereqtext[0].DrawMode = JAM1;
  139.         movereqtext[0].ITextFont = &TestFont;
  140.         movereqtext[0].NextText = NULL;
  141.         movereqtext[0].LeftEdge = 5;
  142.         movereqtext[0].TopEdge = 1;
  143.         movereqtext[0].IText = (UBYTE *)"Move In-Frame:";
  144.  
  145.         return(0);
  146. }
  147.  
  148.  
  149.  
  150. InitMenu()
  151. {
  152. SHORT n,j,k;
  153.  
  154.         menu[0].NextMenu = &menu[1];
  155.         menu[0].LeftEdge = 4;           /* first menu at left edge */
  156.         menu[0].TopEdge = 0;
  157.         menu[0].Width = 44;
  158.         menu[0].Height = 10;
  159.         menu[0].Flags = MENUENABLED;
  160.         menu[0].MenuName = "Color";
  161.         menu[0].FirstItem = &coloritem[0];
  162.  
  163.         menu[1].NextMenu = &menu[2];
  164.         menu[1].LeftEdge = 48;  
  165.         menu[1].TopEdge = 0;
  166.         menu[1].Width = 40;
  167.         menu[1].Height = 10;
  168.         menu[1].Flags = MENUENABLED;
  169.         menu[1].MenuName = "Copy";
  170.         menu[1].FirstItem = ©item[0];
  171.  
  172.         menu[2].NextMenu = &menu[3];
  173.         menu[2].LeftEdge = 88;  
  174.         menu[2].TopEdge = 0;
  175.         menu[2].Width = 40;
  176.         menu[2].Height = 10;
  177.         menu[2].Flags = MENUENABLED;
  178.         menu[2].MenuName = "Move";
  179.         menu[2].FirstItem = &moveitem[0];
  180.  
  181.         menu[3].NextMenu = &menu[4];
  182.         menu[3].LeftEdge = 128; 
  183.         menu[3].TopEdge = 0;
  184.         menu[3].Width = 40;
  185.         menu[3].Height = 10;
  186.         menu[3].Flags = MENUENABLED;
  187.         menu[3].MenuName = "Text";
  188.         menu[3].FirstItem = &textitem[0];
  189.  
  190.         menu[4].NextMenu = &menu[5];
  191.         menu[4].LeftEdge = 168; 
  192.         menu[4].TopEdge = 0;
  193.         menu[4].Width = 40;
  194.         menu[4].Height = 10;
  195.         menu[4].Flags = MENUENABLED;
  196.         menu[4].MenuName = "Disk";
  197.         menu[4].FirstItem = &diskitem[0];
  198.  
  199.         menu[5].NextMenu = NULL;
  200.         menu[5].LeftEdge = 208; 
  201.         menu[5].TopEdge = 0;
  202.         menu[5].Width = 40;
  203.         menu[5].Height = 10;
  204.         menu[5].Flags = MENUENABLED;
  205.         menu[5].MenuName = "Misc";
  206.         menu[5].FirstItem = &miscitem[0];
  207.  
  208.       n=0;
  209.       for(j=0; j<3; j++)
  210.         for(k=0; k<3; k++)
  211.         {
  212.         choiceitem[n].NextItem = &choiceitem[n+1];
  213.         choiceitem[n].LeftEdge = 100 + 30 * k;
  214.         choiceitem[n].TopEdge = -14 + (14 * j);
  215.         choiceitem[n].Width = 30;
  216.         choiceitem[n].Height = 14;
  217.         choiceitem[n].Flags = ITEMTEXT | ITEMENABLED | HIGHBOX ;
  218.         choiceitem[n].MutualExclude = 0;
  219.         choiceitem[n].ItemFill = (APTR)&choicetext[n];
  220.         choiceitem[n].SelectFill = NULL;
  221.         choiceitem[n].Command = 0;
  222.         choiceitem[n].SubItem = NULL;   
  223.         choiceitem[n].NextSelect = 0;   
  224.         n++;
  225.         }
  226.         choiceitem[8].NextItem = NULL;
  227.  
  228.       n=0;
  229.       for(j=0; j<3; j++)
  230.         for(k=0; k<3; k++)
  231.         {
  232.         choiceitem2[n].NextItem = &choiceitem2[n+1];
  233.         choiceitem2[n].LeftEdge = 82 + 30 * k;
  234.         choiceitem2[n].TopEdge = -14 + (14 * j);
  235.         choiceitem2[n].Width = 30;
  236.         choiceitem2[n].Height = 14;
  237.         choiceitem2[n].Flags = ITEMTEXT | ITEMENABLED | HIGHBOX ;
  238.         choiceitem2[n].MutualExclude = 0;
  239.         choiceitem2[n].ItemFill = (APTR)&choicetext[n];
  240.         choiceitem2[n].SelectFill = NULL;
  241.         choiceitem2[n].Command = 0;
  242.         choiceitem2[n].SubItem = NULL;  
  243.         choiceitem2[n].NextSelect = 0;  
  244.         n++;
  245.         }
  246.         choiceitem2[8].NextItem = NULL;
  247.  
  248.   for(n=0; n<2; n++)
  249.         {
  250.         diskitem[n].NextItem = &diskitem[n+1];
  251.         diskitem[n].LeftEdge = 0;
  252.         diskitem[n].TopEdge = 10 * n;
  253.         diskitem[n].Width = 56;
  254.         diskitem[n].Height = 10;
  255.         diskitem[n].Flags = ITEMTEXT | ITEMENABLED | HIGHBOX ;
  256.         diskitem[n].MutualExclude = 0;
  257.         diskitem[n].ItemFill = (APTR)&disktext[n];
  258.         diskitem[n].SelectFill = NULL;
  259.         diskitem[n].Command = 0;
  260.         diskitem[n].SubItem = NULL;     /* there are no subitems on any */
  261.         diskitem[n].NextSelect = 0;     /* not providing for drag select */
  262.         }
  263.         diskitem[1].NextItem = NULL;
  264.  
  265.   for(n=0; n<4; n++)
  266.         {
  267.         copyitem[n].NextItem = ©item[n+1];
  268.         copyitem[n].LeftEdge = 0;
  269.         copyitem[n].TopEdge = 10 * n;
  270.         copyitem[n].Width = 112;
  271.         copyitem[n].Height = 10;
  272.         copyitem[n].Flags = ITEMTEXT | ITEMENABLED | HIGHBOX ;
  273.         copyitem[n].MutualExclude = 0;
  274.         copyitem[n].ItemFill = (APTR)©text[n];
  275.         copyitem[n].SelectFill = NULL;
  276.         copyitem[n].Command = 0;
  277.         copyitem[n].SubItem = NULL;     /* there are no subitems on any */
  278.         copyitem[n].NextSelect = 0;     /* not providing for drag select */
  279.         }
  280.         copyitem[3].NextItem = NULL;
  281.         copyitem[2].SubItem = &choiceitem2[0];
  282.         copyitem[3].SubItem = &choiceitem2[0];
  283.  
  284.   for(n=0; n<3; n++)
  285.         {
  286.         moveitem[n].NextItem = &moveitem[n+1];
  287.         moveitem[n].LeftEdge = 0;
  288.         moveitem[n].TopEdge = 10 * n;
  289.         moveitem[n].Width = 88;
  290.         moveitem[n].Height = 10;
  291.         moveitem[n].Flags = ITEMTEXT | ITEMENABLED | HIGHBOX ;
  292.         moveitem[n].MutualExclude = 0;
  293.         moveitem[n].ItemFill = (APTR)&movetext[n];
  294.         moveitem[n].SelectFill = NULL;
  295.         moveitem[n].Command = 0;
  296.         moveitem[n].SubItem = NULL;     /* there are no subitems on any */
  297.         moveitem[n].NextSelect = 0;     /* not providing for drag select */
  298.         }
  299.         moveitem[2].NextItem = NULL;
  300.         moveitem[2].SubItem = &choiceitem2[0];
  301.  
  302.   for(n=0; n<2; n++)
  303.         {
  304.         textitem[n].NextItem = &textitem[n+1];
  305.         textitem[n].LeftEdge = 0;
  306.         textitem[n].TopEdge = 10 * n;
  307.         textitem[n].Width = 100;
  308.         textitem[n].Height = 10;
  309.         textitem[n].Flags = ITEMTEXT | ITEMENABLED | HIGHBOX ;
  310.         textitem[n].MutualExclude = 0;
  311.         textitem[n].ItemFill = (APTR)&texttext[n];
  312.         textitem[n].SelectFill = NULL;
  313.         textitem[n].Command = 0;
  314.         textitem[n].NextSelect = 0;     /* not providing for drag select */
  315.         }
  316.         textitem[1].NextItem = NULL;
  317. /*      textitem[0].SubItem = &jamitem[0];
  318.         textitem[1].SubItem = &topazitem[0];
  319. */
  320.   for(n=0; n<5; n++)
  321.         {
  322.         miscitem[n].NextItem = &miscitem[n+1];
  323.         miscitem[n].LeftEdge = -40;
  324.         miscitem[n].TopEdge = 10 * n;
  325.         miscitem[n].Width = 124;
  326.         miscitem[n].Height = 10;
  327.         miscitem[n].Flags = ITEMTEXT | ITEMENABLED | HIGHBOX ;
  328.         miscitem[n].MutualExclude = 0;
  329.         miscitem[n].ItemFill = (APTR)&misctext[n];
  330.         miscitem[n].SelectFill = NULL;
  331.         miscitem[n].Command = 0;
  332.         miscitem[n].SubItem = NULL;     /* there are no subitems on any */
  333.         miscitem[n].NextSelect = 0;     /* not providing for drag select */
  334.         }
  335.         miscitem[4].NextItem = NULL;
  336.  
  337.   for(n=0; n<2; n++)
  338.         {
  339.         jamitem[n].NextItem = &jamitem[n+1];
  340.         jamitem[n].LeftEdge = 56;
  341.         jamitem[n].TopEdge = 10 * n;
  342.         jamitem[n].Width = 76;
  343.         jamitem[n].Height = 10;
  344.         jamitem[n].Flags = ITEMTEXT | ITEMENABLED | HIGHBOX ;
  345.         jamitem[n].MutualExclude = 0;
  346.         jamitem[n].ItemFill = (APTR)&jamtext[n];
  347.         jamitem[n].SelectFill = NULL;
  348.         jamitem[n].Command = 0;
  349.         jamitem[n].SubItem = NULL;      /* there are no subitems on any */
  350.         jamitem[n].NextSelect = 0;      /* not providing for drag select */
  351.         }
  352.         jamitem[1].NextItem = NULL;
  353.  
  354.   for(n=0; n<2; n++)
  355.         {
  356.         topazitem[n].NextItem = &topazitem[n+1];
  357.         topazitem[n].LeftEdge = 56;
  358.         topazitem[n].TopEdge = 10 * n;
  359.         topazitem[n].Width = 76;
  360.         topazitem[n].Height = 10;
  361.         topazitem[n].Flags = ITEMTEXT | ITEMENABLED | HIGHBOX ;
  362.         topazitem[n].MutualExclude = 0;
  363.         topazitem[n].ItemFill = (APTR)&topaztext[n];
  364.         topazitem[n].SelectFill = NULL;
  365.         topazitem[n].Command = 0;
  366.         topazitem[n].SubItem = NULL;    /* there are no subitems on any */
  367.         topazitem[n].NextSelect = 0;    /* not providing for drag select */
  368.         }
  369.         topazitem[1].NextItem = NULL;
  370.  
  371.  
  372.  
  373.         InitColorItems(DEPTH);
  374.         InitCopyText();
  375.         InitMoveText();
  376.         InitTextText();
  377.         InitDiskText();
  378.         InitMiscText();
  379.         InitChoiceText();
  380.  
  381.         InitJamText();
  382.         InitTopazText();
  383.         
  384.         InitDirectText();  
  385.         InitMyRequest();
  386.  
  387.         return(0);
  388. }
  389.  
  390.  
  391.  
  392. InitDirectText()
  393. {
  394. SHORT n;
  395.    for(n=0; n<5; n++)
  396.         {       
  397.         directtext[n].FrontPen = 1;
  398.         directtext[n].BackPen = 0;
  399.         directtext[n].DrawMode = JAM2;
  400.         directtext[n].ITextFont = &TestFont;
  401.         directtext[n].NextText = NULL;
  402.         directtext[n].LeftEdge = 0;
  403.         directtext[n].TopEdge = 1;
  404.         }
  405.         directtext[0].IText = (UBYTE *)"Left";
  406.         directtext[1].IText = (UBYTE *)"Right";
  407.         directtext[2].IText = (UBYTE *)"Up";
  408.         directtext[3].IText = (UBYTE *)"Down";
  409.         directtext[4].IText = (UBYTE *)"EXIT";
  410. return(0);
  411. }
  412.  
  413.  
  414. InitChoiceText()
  415. {
  416. SHORT n;
  417.    for(n=0; n<9; n++)
  418.         {       
  419.         choicetext[n].FrontPen = 0;
  420.         choicetext[n].BackPen = 1;
  421.         choicetext[n].DrawMode = JAM2;
  422.         choicetext[n].LeftEdge = 8;
  423.         choicetext[n].TopEdge = 5;
  424.         choicetext[n].ITextFont = &TestFont;
  425.         choicetext[n].NextText = NULL;
  426.         }
  427.  
  428.         choicetext[0].IText = (UBYTE *)"1";
  429.         choicetext[1].IText = (UBYTE *)"2";
  430.         choicetext[2].IText = (UBYTE *)"3";
  431.         choicetext[3].IText = (UBYTE *)"4";
  432.         choicetext[4].IText = (UBYTE *)"5";
  433.         choicetext[5].IText = (UBYTE *)"6";
  434.         choicetext[6].IText = (UBYTE *)"7";
  435.         choicetext[7].IText = (UBYTE *)"8";
  436.         choicetext[8].IText = (UBYTE *)"9";
  437.         
  438.         return(0);
  439. }
  440.  
  441. InitDiskText()
  442. {
  443. SHORT n;
  444.    for(n=0; n<2; n++)
  445.         {       
  446.         disktext[n].FrontPen = 0;
  447.         disktext[n].BackPen = 1;
  448.         disktext[n].DrawMode = JAM2;
  449.         disktext[n].LeftEdge = 0;
  450.         disktext[n].TopEdge = 1;
  451.         disktext[n].ITextFont = &TestFont;
  452.         disktext[n].NextText = NULL;
  453.         }
  454.         disktext[0].IText = (UBYTE *)"Save";
  455.         disktext[1].IText = (UBYTE *)"Load";
  456.         
  457.         return(0);
  458.         
  459. InitCopyText()
  460. {
  461. SHORT n;
  462.    for(n=0; n<4; n++)
  463.         {       
  464.         copytext[n].FrontPen = 0;
  465.         copytext[n].BackPen = 1;
  466.         copytext[n].DrawMode = JAM2;
  467.         copytext[n].LeftEdge = 0;
  468.         copytext[n].TopEdge = 1;
  469.         copytext[n].ITextFont = &TestFont;
  470.         copytext[n].NextText = NULL;
  471.         }
  472.  
  473.         copytext[0].IText = (UBYTE *)"Undo";
  474.         copytext[1].IText = (UBYTE *)"Snapshot";
  475.         copytext[2].IText = (UBYTE *)"From-Frame";
  476.         copytext[3].IText = (UBYTE *)"Merge-With";
  477.         
  478.         return(0);
  479.  
  480. InitMoveText()
  481. {
  482. SHORT n;
  483.    for(n=0; n<3; n++)
  484.         {       
  485.         movetext[n].FrontPen = 0;
  486.         movetext[n].BackPen = 1;
  487.         movetext[n].DrawMode = JAM2;
  488.         movetext[n].LeftEdge = 0;
  489.         movetext[n].TopEdge = 1;
  490.         movetext[n].ITextFont = &TestFont;
  491.         movetext[n].NextText = NULL;
  492.         }
  493.  
  494.         movetext[0].IText = (UBYTE *)"Animate";
  495.         movetext[1].IText = (UBYTE *)"In-Frame";
  496.         movetext[2].IText = (UBYTE *)"Exchange";
  497.         
  498.         return(0);
  499. }
  500.  
  501.  
  502. InitTextText()
  503. {
  504. SHORT n;
  505.    for(n=0; n<2; n++)
  506.         {       
  507.         texttext[n].FrontPen = 0;
  508.         texttext[n].BackPen = 1;
  509.         texttext[n].DrawMode = JAM2;
  510.         texttext[n].LeftEdge = 0;
  511.         texttext[n].TopEdge = 1;
  512.         texttext[n].ITextFont = &TestFont;
  513.         texttext[n].NextText = NULL;
  514.         }
  515.  
  516.         texttext[0].IText = (UBYTE *)"Into Frame";
  517.         texttext[1].IText = (UBYTE *)"Set Colors";
  518. /*      texttext[2].IText = "Color";    */ 
  519.         
  520.         return(0);
  521. }
  522.  
  523. InitMiscText()
  524. {
  525. SHORT n;
  526.    for(n=0; n<5; n++)
  527.         {       
  528.         misctext[n].FrontPen = 0;
  529.         misctext[n].BackPen = 1;
  530.         misctext[n].DrawMode = JAM2;
  531.         misctext[n].LeftEdge = 0;
  532.         misctext[n].TopEdge = 1;
  533.         misctext[n].ITextFont = &TestFont;
  534.         misctext[n].NextText = NULL;
  535.         }
  536.  
  537.         misctext[0].IText = (UBYTE *)"  HELP!   ";
  538.         misctext[1].IText = (UBYTE *)"  Clear    ";
  539.         misctext[2].IText = (UBYTE *)"ScrollViews";
  540.         misctext[3].IText = (UBYTE *)"Reconfigure";
  541.         misctext[4].IText = (UBYTE *)"Exit Program";    
  542.         return(0);
  543. }
  544.  
  545. InitJamText()
  546. {
  547. SHORT n;
  548.    for(n=0; n<2; n++)
  549.         {       
  550.         jamtext[n].FrontPen = 0;
  551.         jamtext[n].BackPen = 1;
  552.         jamtext[n].DrawMode = JAM2;
  553.         jamtext[n].LeftEdge = 0;
  554.         jamtext[n].TopEdge = 1;
  555.         jamtext[n].ITextFont = &TestFont;
  556.         jamtext[n].NextText = NULL;
  557.         }
  558.         jamtext[0].IText = (UBYTE *)"JAM1";
  559.         jamtext[1].IText = (UBYTE *)"JAM2";
  560.         return(0);
  561. }
  562.  
  563. InitTopazText()
  564. {
  565. SHORT n;
  566.    for(n=0; n<2; n++)
  567.         {       
  568.         topaztext[n].FrontPen = 0;
  569.         topaztext[n].BackPen = 1;
  570.         topaztext[n].DrawMode = JAM2;
  571.         topaztext[n].LeftEdge = 0;
  572.         topaztext[n].TopEdge = 1;
  573.         topaztext[n].ITextFont = &TestFont;
  574.         topaztext[n].NextText = NULL;
  575.         }
  576.         topaztext[0].IText = (UBYTE *)"Topaz-60";
  577.         topaztext[1].IText = (UBYTE *)"Topaz-80";
  578.         return(0);
  579.  
  580.